package com.charging.system.service;

import java.util.List;
import com.charging.system.domain.KxChargingRecord;

/**
 * 充电记录Service接口
 *
 * @author charging
 * @date 2024-04-19
 */
public interface IKxChargingRecordService
{
    /**
     * 查询充电记录
     *
     * @param chargingRecordId 充电记录主键
     * @return 充电记录
     */
    public KxChargingRecord selectKxChargingRecordByChargingRecordId(Long chargingRecordId);

    /**
     * 查询充电记录列表
     *
     * @param kxChargingRecord 充电记录
     * @return 充电记录集合
     */
    public List<KxChargingRecord> selectKxChargingRecordList(KxChargingRecord kxChargingRecord);

    /**
     * 新增充电记录
     *
     * @param kxChargingRecord 充电记录
     * @return 结果
     */
    public int insertKxChargingRecord(KxChargingRecord kxChargingRecord);

    /**
     * 修改充电记录
     *
     * @param kxChargingRecord 充电记录
     * @return 结果
     */
    public int updateKxChargingRecord(KxChargingRecord kxChargingRecord);

    /**
     * 批量删除充电记录
     *
     * @param chargingRecordIds 需要删除的充电记录主键集合
     * @return 结果
     */
    public int deleteKxChargingRecordByChargingRecordIds(Long[] chargingRecordIds);

    /**
     * 删除充电记录信息
     *
     * @param chargingRecordId 充电记录主键
     * @return 结果
     */
    public int deleteKxChargingRecordByChargingRecordId(Long chargingRecordId);

    /**
     * 获取充电中的插座
     * @param kxChargingRecord
     * @return
     */
    List<Integer> getChargingChannelNos(KxChargingRecord kxChargingRecord);

    /**
     * 更新充电功率
     * @param kxChargingRecord
     * @return
     */
    int updateChargingPower(KxChargingRecord kxChargingRecord);

    /**
     * 获取正在充电插口号
     * @param equipNo
     * @return
     */
    List<Integer> getEquipChargingNos(String equipNo);


    /**
     * 执行计费逻辑
     * @param kxChargingRecords
     */
    void chargingAction(List<KxChargingRecord> kxChargingRecords);

}
